package com.example.websocket;

import cn.hutool.cron.CronUtil;
import com.example.websocket.task.test.TestJob2;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;

@SpringBootApplication
public class Websocket1Application {

    public static void main(String[] args) {
        ConfigurableApplicationContext context = SpringApplication.run(Websocket1Application.class, args);
        TestJob2 testJob2 = context.getBean(TestJob2.class);
        //开启支持秒级匹配
        CronUtil.setMatchSecond(true);
        //启动定时任务
        //CronUtil.start();
        //testJob2.execute();
    }

}
